<?php
// 本类由系统自动生成，仅供测试用途
class DepartmentAction extends CommonAction {
	public function _before_index() {
		$model = M ( "Department" );
		$list = $model->where ( 'parentid=0' )->getField ( 'id,depname,depdesc,deplevel,fax' );
		$this->assign ( 'groupList', $list );
	}
	public function _before_add() {
		$model = M ( "Department" );
		$list = $model->select ();
		$this->assign ( 'list', $list );
	}
	public function _before_edit() {
		$model = M ( "Department" );
		$list = $model->select ();
		$this->assign ( 'list', $list );
	}
}